package com.multi.web.controller.common;

import com.multi.common.core.domain.AjaxResult;
import com.multi.publicly.domain.WxUserInfo;
import com.multi.publicly.resp.WxUserInfoResp;
import com.multi.publicly.service.WxUserInfoService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @Description 微信用户管理控制器
 * @ClassName UserInfoController
 * @Author pzj
 * @Data 2024/12/4 11:24
 */
@RestController
@RequestMapping("app/user")
public class UserInfoController {

    @Autowired
    private WxUserInfoService wxUserInfoService;

    /**
     * 获取微信用户基本信息
     * @return
     */
    @GetMapping("profile")
    public AjaxResult getUserProfile(){
        WxUserInfoResp wxUserInfoResp= wxUserInfoService.getUserProfile();
        return AjaxResult.success(wxUserInfoResp);
    }
}
